package com.wtb.javatool.entity;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.data.annotation.CreatedDate;
import org.springframework.data.annotation.LastModifiedDate;
import org.springframework.data.jpa.domain.support.AuditingEntityListener;

import javax.persistence.EntityListeners;
import java.util.Date;


/**
 * 用户表
 *
 * @author gaozhen
 */
@Data
@ApiModel(value = "User", description = "用户实体")

public class User {
    @ApiModelProperty(value = "用户ID", example = "10001")
    private Long userId;

    @ApiModelProperty(value = "用户名", example = "张三")
    private String userName;

    @ApiModelProperty(value = "密码", example = "123456")
    private String password;

    @ApiModelProperty(value = "手机号", example = "13800138000")
    private String phone;

    @ApiModelProperty(value = "邮箱", example = "user@example.com")
    private String email;

    @ApiModelProperty(value = "创建时间", example = "2023-01-01 00:00:00")
    private Date createdAt;

    @ApiModelProperty(value = "更新时间", example = "2023-01-01 00:00:00")
    private Date updatedAt;

    @ApiModelProperty(value = "角色",example = "student | teacher")
    private int role;

}